import React, { useState, useEffect } from "react";
import { useAuth } from "./AuthContext";
import useRandomTitle from "./hooks/useRandomTitle";


export default function SayHello () {
  const greetings = ["Hello", "Ciao", "Hola", "こんにちは"];

  const { logout } = useAuth()

  console.log('hello....')
  
  const nextTitle = useRandomTitle(greetings);
  
  return <>
    <button onClick={nextTitle}>Say Hi</button>&nbsp;&nbsp;
    <button onClick={logout}>Test Logout</button>
  </>
}